package org.dev.vlp.service;

import org.dev.vlp.entity.Word;
import org.dev.vlp.entity.WordCollection;
import com.baomidou.mybatisplus.extension.service.IService;

import java.util.List;

/**
* @author 86184
* @description 针对表【vlp_word_collection】的数据库操作Service
* @createDate 2023-01-16 21:52:33
*/
public interface WordCollectionService extends IService<WordCollection> {

    // 查询单词是否被收藏过
    boolean wordIsCollected(long userId, long wordId);

    // 收藏单词
    void collectWord(long userId, long wordId);

    // 取消收藏单词
    void cancelCollectWord(long userId, long wordId);

    // 获取收藏单词列表
    List<Word> getCollectionList(long userId);

}
